ilowest()

ilowest() | Previous Top Next

Returns the shift of the minimum value over a specific number of bars depending on type.
int ilowest(int timeframe, // timeframe
int type, // timeseries
int count, // count
int start=0 // start
);
Parameters
timeframe
[in] Timeframe. It can be any of PERIOD_ enumeration values.
type
[in] Series array identifier. It can be any of the MODE_ enumeration values.
count=WHOLE_ARRAY
[in] Number of bars (in direction from the start bar to the back one) on which the search is carried out.
start=0
[in] Shift showing the bar, relative to the current bar, that the data should be taken from.
Returned value
The shift of the minimum value over a specific number of bars or -1 if error.
Example:

double val;
//--- calculating the lowest value on the 20 consecutive bars in the range
//--- from the 4th to the 23rd index inclusive on the current chart
int val_index=[ilowest(1440,MODE_LOW,20,4)];
if(val_index!=-1) val=lowa[val_index];
else Printf("Error in call ilowest.");